import {actionT}  from './actionTypes'
import axios from 'axios'
export const changeInputAction = (value)=>({
    type:actionT.changeInput,
    value
})
export const addItemAction = ()=>({
    type:actionT.addItem
})

export const deleteItemAction = (index)=>({
    type:actionT.deleteItem,
    index
})
export const getListAction  = (data)=>({
    type:actionT.GET_LIST,
    data
})
export const getTodoList = () =>{
    return ()=>{
        axios.get('https://www.easy-mock.com/mock/5cfcce489dc7c36bd6da2c99/xiaojiejie/getList').then((res)=>{
            const data = res.data
            console.log(data)
        })
    }
}